package com.chen.controller;


import com.chen.service.CouponService;
import com.chen.vo.Result;
import io.swagger.annotations.ApiModelProperty;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * <p>
 * 优惠券表 前端控制器
 * </p>
 *
 * @author cws
 * @since 2024-11-22
 */
@RestController
@RequestMapping("/mall/coupon")
public class CouponController {


    @Resource
    private CouponService couponService;


    @ApiModelProperty(value = "更具商品获取指定优惠卷及不指定优惠卷")
    @GetMapping("/couponList")
    public Result couponList(@RequestParam("productId") Long productId,@RequestParam("regionId") Long regionId){
        return couponService.couponList(productId,regionId);
    }


}

